function [GlobKs,GlobBs]=CalculateSurfaceKeBe(NodePt,SurfaceNd)
NodeNum=size(NodePt);
SurfaceSize=size(SurfaceNd);

GlobKs=zeros(NodeNum(1));
GlobBs=zeros(NodeNum(1),1);

for n=1:SurfaceSize(1)
    for ni=1:2
        FlagNi=SurfaceNd(n,ni+1);
        GlobKs(FlagNi,FlagNi)=GlobKs(FlagNi,FlagNi)+1e15;
    end
end

for n=1:SurfaceSize(1)
    if 5710<=SurfaceNd(n,1)&&SurfaceNd(n,1)<=5769
        for ni=1:2
            FlagNi=SurfaceNd(n,ni+1);
            GlobBs(FlagNi)=GlobBs(FlagNi)+1e15*0;
        end
    elseif 5770<=SurfaceNd(n,1)&&SurfaceNd(n,1)<=5809
        for ni=1:2
            FlagNi=SurfaceNd(n,ni+1);
            x=NodePt(FlagNi,2);
            y=NodePt(FlagNi,3);
            GlobBs(FlagNi)=GlobBs(FlagNi)+1e15*sin(3*pi*y/2);
        end
    elseif 5810<=SurfaceNd(n,1)&&SurfaceNd(n,1)<=5869
        for ni=1:2
            FlagNi=SurfaceNd(n,ni+1);
            x=NodePt(FlagNi,2);
            y=NodePt(FlagNi,3);
            GlobBs(FlagNi)=GlobBs(FlagNi)+1e15*sin(3*pi*x/3)*cos(pi*x/3);
        end
    elseif 5870<=SurfaceNd(n,1)&&SurfaceNd(n,1)<=5909
        for ni=1:2
            FlagNi=SurfaceNd(n,ni+1);
            GlobBs(FlagNi)=GlobBs(FlagNi)+1e15*0;
        end
    end
end